{layout '../Public/sideForm.latte'}
{block title}审核积分{/block}


{block private_css}
    <style>
        .priority-input span{
            margin:auto !important;
            display:block;
            width:30px;
            height:30px;
            line-height:30px;
            border-radius:50%;
            cursor:pointer;
        }

        .medal-item img{
            width:30px;
            height:30px;
            vertical-align:middle;
        }

        .acorn-item dt{
            text-align:center;
            font-size:14px;
            height:30px;
            line-height:30px;
        }

        .acorn-item dd input{
            width:100% !important;
            text-align:center;
            padding-left:0 !important;
        }
    </style>
{/block}

{block private_js}
    <script>
        init.ready(function () {
            $(".priority-input").unbind().bind("click", function () {
                $(this).siblings(".selected").removeClass("selected");
                $(this).addClass("selected");
            });
            $(".medal-item").unbind().bind("click", function () {
                $(this).siblings(".medal-item-selected").removeClass("medal-item-selected");
                $(this).addClass("medal-item-selected");
                var val = $(this).attr("data-val");
                $("#medal").val(val);
            });
            $(".layer-photos").unbind().bind("click", function () {
                var src = $(this).attr("layer-src");
                var up = uploader.initPreview("", null);
                up.imgShow(src);
            });

        });
    </script>
{/block}


{block content}
    <form id="formArticle" class="stdform mform" method="post" action="">
        <table cellpadding="0" cellspacing="0" border="0" id="frmtable" class="formtable">
            <thead>
            <tr>
                <td><label>积分事项</label></td>
                <td>
                    <div class="field control-group">
                        <div class="input-group">
                            <input type="text" id="frm_names" name="aaNames" class="smallinput" value="{$standardEN['names']?$standardEN['names']:'该维度不存在'}" readonly="readonly"/>
                        </div>
                    </div>
                </td>
            </tr>
            <tr>
                <td><label>积分分数</label></td>
                <td>
                    <div class="field control-group">
                        <div class="input-group">
                            <input type="text" id="frm_acorn" name="acorn" class="smallinput" value="{$lists['acorn']}" {if $lists['auditor']!=$userId}readonly{/if}/>分
                            <input type="hidden" name="__token__" value="{$__token__}">
                        </div>
                    </div>
                </td>
            </tr>
            <tr style="line-height:36px;">
                <td><label style="line-height:36px;">奖扣对象</label></td>
                <td>
                    <div class="field control-group" style="line-height:36px;">
                        {$toUser}
                    </div>
                </td>
            </tr>
            <tr>
                <td><label>申请说明</label></td>
                <td>
                    <div class="field control-group">
                        <div class="input-group" style="line-height:28px;padding-right:30%">
                            {if $lists['memo']}
                                {$lists['memo']|noescape}
                            {else}
                                无
                            {/if}

                        </div>
                    </div>
                </td>
            </tr>
            <tr>
                <td><label>附 件</label></td>
            </tr>
            <tr>
                <td><label></label></td>
                <td>
                    <dl>
                        <dd style="font-size:14px">
                            {if !$thumbs}无
                            {else}
                                {foreach $thumbs as $thumb}
                                    {if $thumb["type"]=="img"}
                                        <img class="layer-photos" layer-pid="" layer-src="{$thumb['src']}" style="max-width:150px;max-height:150px;cursor:pointer" src="{$cdnThumbBase}{$thumb['val']}" alt="{$thumb['name']}">
                                    {else}
                                        <a href="{$thumb['src']}" title="{$thumb['val']}" target="_blank">{$thumb['name']}</a>
                                    {/if}
                                {/foreach}
                            {/if}
                        </dd>
                    </dl>
                </td>
            </tr>
            {if $lists['auditor']==$userId}
                <tr>
                    <td><label>说明/评论</label></td>
                    <td>
                        <div class="field control-group">
                            <div class="input-group">
                                <textarea name="sysMemo"></textarea>
                            </div>
                        </div>
                    </td>
                </tr>
                <tr>
                    <td><label>状态</label></td>
                    <td>
                        <div class="field control-group">
                            <div class="input-group">
                                <label class='radio'><input name='status' checked type="radio" value='1'>已审核</label>
                                <label class='radio'><input name='status' type="radio" value='2'>不通过</label>
                            </div>
                        </div>
                    </td>
                </tr>
            {else}
                <tr>
                    <td><label>说明/评论</label></td>
                    <td>
                        <div class="field control-group">
                            <div class="input-group">
                                {if $lists['sysMemo']}
                                    {$lists['sysMemo']}
                                {else}
                                    暂无
                                {/if}
                            </div>
                        </div>
                    </td>
                </tr>
                <tr>
                    <td><label>状态</label></td>
                    <td>
                        <div class="field control-group">
                            <div class="input-group">
                                {$lists['statusMemo']}
                            </div>
                        </div>
                    </td>
                </tr>
            {/if}
            </thead>
        </table>
    </form>
{/block}
{block submits}
    {if  $lists['auditor']==$userId}
        <div class="contenteditsSubmits">
            <div class="contenteditsSubmit">提交</div>
        </div>
    {else}
        <div class="contenteditsSubmits">
            <div class="contenteditsSubmit">已阅</div>
        </div>
    {/if}
{/block}